package com.market.sys.api.client;/*
 *文件名: NoticeController
 *创建时间:2024/4/1 19:46
 *version: 1.0
 *since: 1.0
 */

import com.market.sys.common.Result;
import com.market.sys.service.INoticeService;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/sys/notice")
public class NoticeController {

    @Resource
    private INoticeService noticeService;

    @PostMapping("/list")
    public Result<?> list(){
        return Result.success(noticeService.query().orderByDesc("id").list());
    }
}
